﻿#ifndef DLGREPORTMEALS_H
#define DLGREPORTMEALS_H

//(*Headers(DlgUser)
#include <wx/dialog.h>
//*)
#include <wx/textctrl.h>
#include <wx/button.h>
#include <wx/choice.h>
#include <wx/combobox.h>
#include <wx/listctrl.h>
#include <wx/datectrl.h>
#include <wx/log.h>
#include <vector>
#include <utility>
#include "PublicData.h"
using std::vector;
using std::pair;

class CDlgReportMeals: public wxDialog
{
public:

    CDlgReportMeals(wxWindow* parent,wxWindowID id=wxID_ANY,const wxPoint& pos=wxDefaultPosition,const wxSize& size=wxDefaultSize);
    virtual ~CDlgReportMeals();

private:
//控件ID
    static const long IDC_BTN_EXIT;
    static const long IDC_BTN_SEARCH;
    static const long IDC_COMBO_TYPE;
    static const long IDC_COMBO_TIME;
    static const long IDC_COMBO_SEARCH;
    static const long IDC_EDIT_SEARCH;
    static const long IDC_EDIT_BALANCE;
    static const long IDC_EDIT_USER;
    static const long IDC_RICHEDIT_REMARK;
    static const long IDC_THEDAY;
    static const long IDC_LIST;
    static const long IDC_TIMEFROM;
    static const long IDC_TIMETO;
    static const long IDC_EDIT_STATIC;

    //控件变量
    wxBoxSizer *topSizer_;
    wxButton *btn_Search_;
    wxButton *btn_Exit_;
    wxChoice *combo_search_;
    wxComboBox *combo_time_;
    wxComboBox *combo_type_;
    wxTextCtrl *text_search_;
    wxTextCtrl *text_balance_;
    wxTextCtrl *text_user_;
    wxTextCtrl *text_remark_;
    wxDatePickerCtrl *time_;
    wxListCtrl *list_;
    wxDatePickerCtrl *timefrom_;
    wxDatePickerCtrl *timeto_;
    wxTextCtrl *text_stat_;

    //控件事件
    void OnBnClickedBtnSearch(wxCommandEvent& event);
    void OnBnClickedBtnExit(wxCommandEvent& event);
    void OnNMClickList(wxListEvent& event);

    //自定义函数
    void CreateCtrlAndEvent();//创建控件
    void InitComboBoxAndListCtrl();
    DECLARE_EVENT_TABLE()
};

#endif
